# test.py
import sys
import io
from gen import generate_data
from alg import max_uncrossed_lines

# 防止中文乱码（可保留）
sys.stdout = io.TextIOWrapper(sys.stdout.buffer, encoding='utf-8')

if __name__ == "__main__":
    nums1, nums2 = generate_data(length_range=(3, 10), value_range=(1, 5))
    print(f"nums1 = {nums1}")
    print(f"nums2 = {nums2}")
    result = max_uncrossed_lines(nums1, nums2)
    print(result)
